package org.joa.manager.persistence;

import java.io.IOException;

import org.joa.actor.Actor;
import org.joa.actor.ActorName;

public interface PersistenceManagerInterface {

    public void storeRevision(Actor actor, long revision) throws IOException;

    public Actor restoreRevision(ActorName actorName, Class<? extends Actor> actorClass,
        long revision) throws IOException, ClassNotFoundException, IllegalArgumentException, IllegalAccessException;

    public byte[] serialize(Actor actor) throws IOException;

    public Actor deserialize(byte[] data, Class<? extends Actor> actorClass) throws IOException,
        ClassNotFoundException, IllegalArgumentException, IllegalAccessException;
}
